#include "ibc_nav.h"
#include <stdint.h>


// 示例数据：
// strD1 = "EB 90 7C D1 00 00 00 00 01 E6 FD 8E 3C E6 FD 0E BD CD B1 95 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 F2 79 58 45 5A AB D3 17 9C 18 00 00 9C 18 00 00 9C 18 00 00 00 00 80 3F 00 00 00 C0 00 00 40 40 00 00 00 00 00 00 80 3F 00 00 80 3F CD CC 1C 41 0F 00 00 00 00 03 08 03 05 19 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 CD CC CC 3D 00 00 00 DC 08 02 00 00 C0 19"
// strDA = "EB 90 B4 DA 00 00 00 00 01 00 00 00 00 00 80 3F 00 00 00 40 00 00 40 40 00 00 80 40 00 00 A0 40 00 00 C0 40 00 00 E0 40 00 00 00 41 00 00 10 41 00 00 20 41 00 00 30 41 00 00 40 41 00 00 50 41 00 00 60 41 00 00 70 41 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1B 1F 77 5B F3 03 65 40 6D 7C DC 6D CD 8F 42 40 00 00 00 00 00 80 50 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 D8 13"
int main()
{
    IBCnav_init();

    // Test case 1: Normal data input
    uint8_t data1[] = {
        0xEB, 0x90, 0x7C, 0xD1, 0x00, 0x00, 0x00, 0x00, 0x01, 0xE6, 0xFD, 0x8E, 0x3C, 0xE6, 0xFD, 0x0E, 0xBD, 0xCD, 0xB1, 0x95, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF2, 0x79, 0x58, 0x45, 0x5A, 0xAB, 0xD3, 0x17, 0x9C, 0x18, 0x00, 0x00, 0x9C, 0x18, 0x00, 0x00, 0x9C, 0x18, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3F, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x00, 0x40, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3F, 0x00, 0x00, 0x80, 0x3F, 0xCD, 0xCC, 0x1C, 0x41, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x03, 0x08, 0x03, 0x05, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xCD, 0xCC, 0xCC, 0x3D, 0x00, 0x00, 0x00, 0xDC, 0x08, 0x02, 0x00, 0x00, 0xC0, 0x19,
        0xEB, 0x90, 0xB4, 0xDA, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x3F, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x40, 0x40, 0x00, 0x00, 0x80, 0x40, 0x00, 0x00, 0xA0, 0x40, 0x00, 0x00, 0xC0, 0x40, 0x00, 0x00, 0xE0, 0x40, 0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x10, 0x41, 0x00, 0x00, 0x20, 0x41, 0x00, 0x00, 0x30, 0x41, 0x00, 0x00, 0x40, 0x41, 0x00, 0x00, 0x50, 0x41, 0x00, 0x00, 0x60, 0x41, 0x00, 0x00, 0x70, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1B, 0x1F, 0x77, 0x5B, 0xF3, 0x03, 0x65, 0x40, 0x6D, 0x7C, 0xDC, 0x6D, 0xCD, 0x8F, 0x42, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x50, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xD8, 0x13};

    for (int i = 0; i < sizeof(data1); i++)
    {
        IBCnav_pushData(data1[i]);
    }

    IBCnav_prfOriginData(printf);
    IBCnav_prfFusionData(printf);


    return 1;
}
